<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title>积分平台</title>
		<meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1, user-scalable=no">
		<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=0">
        <meta name="apple-mobile-web-app-capable" content="yes">
        <meta name="apple-mobile-web-app-status-bar-style" content="black">
		<link rel="stylesheet" type="text/css" href="__INDEX__/mui/css/mui.min.css"/>
		<link rel="stylesheet" type="text/css" href="__INDEX__/css/iconfont.css"/>
		<link rel="stylesheet" type="text/css" href="__INDEX__/css/common.css"/>
		<link rel="stylesheet" type="text/css" href="__INDEX__/css/coreIntManageBonus.css"/>
		<script src="__INDEX__/js/lib/font.js" type="text/javascript" charset="utf-8"></script>
	</head>
	<body >
	    <header class="mui-bar mui-bar-nav">
	        <a class="mui-icon mui-icon-left-nav mui-pull-left goindex" style="color: #ffffff"></a>
	        <h1 class="mui-title"></h1>
	    </header>
	    <div class="mui-content">
	    	<div class="modular">
	    		<div class="title">
	    			<div class="head-portrait mui-pull-left" data-color="#F8E71D">
		        		<!--<span class="portrait-name">余光</span>-->
						{if $jiafenren['portrait']}
						<img src="{:getImg($jiafenren['portrait'])}" width="100%" style="border-radius: 50%"/>
						{else}
						<img src="__INDEX__/images/touxiang.jpg" width="100%" style="border-radius: 50%"/>
						{/if}
		        	</div>
		        	<div class="staffInfo mui-pull-left">
		        		<p class="head-name">{$jiafenren['nickname']}</p>
		        		<p class="title-dep">{$jiafenren['departmen_name']}</p>
		        	</div>
		        	<div class="newJiFen mui-pull-right">
		        		<img src="__INDEX__/images/jifen2.png"/><span>{$jiafenren['integral']}分</span>
		        	</div>
	    		</div>
	    	</div>
	    	<div class="modular bonusPoints">
    			<div class="bonusPoints-top">加分</div>
    			<div class="bonusPoints-cont">
    				<div class="cont-fenshu">

    					<button data-num="5">5</button>
    					<button data-num="10">10</button>
    					<button data-num="20">20</button>
    					<button data-num="50">50</button>
    					<button data-num="100">100</button>
    				</div>
    			</div>
    			<div class="bonusPoints-input">
    				<input type="number" name="number" id="number" value="" placeholder="自定义添加分数" />
    				<div class="tianjia-back mui-pull-right">
    					<img src="__INDEX__/images/jiahao.png"/>
    				</div>
    			</div>
    			<ul class="totalNumber" >
    				<!--<li data-num="100">-->
    					<!--<div class="mui-icon mui-pull-left jianhao">-->
    						<!--<span class="jianhao-line"></span>-->
    					<!--</div>-->
    					<!--<div class="mui-pull-right">-->
    						<!--<img class="jifenImg mui-pull-left" src="__INDEX__/images/jifen2.png" />-->
    						<!--<span class="jiaNumber" >100分</span>-->
    					<!--</div>-->
    				<!--</li>-->
    				<!--<li data-num="20">-->
    					<!--<div class="mui-icon mui-pull-left jianhao">-->
    						<!--<span class="jianhao-line"></span>-->
    					<!--</div>-->
    					<!--<div class="mui-pull-right">-->
    						<!--<img class="jifenImg mui-pull-left" src="__INDEX__/images/jifen2.png" />-->
    						<!--<span class="jiaNumber">20分</span>-->
    					<!--</div>-->
    				<!--</li>-->
    				<!--<li data-num="5">-->
    					<!--<div class="mui-icon mui-pull-left jianhao">-->
    						<!--<span class="jianhao-line"></span>-->
    					<!--</div>-->
    					<!--<div class="mui-pull-right">-->
    						<!--<img class="jifenImg mui-pull-left" src="__INDEX__/images/jifen2.png" />-->
    						<!--<span class="jiaNumber">5分</span>-->
    					<!--</div>-->
    				<!--</li>-->
    			</ul>
	    	</div>
	    	<div class="modular">
	    		<textarea name="change_describes" rows="" id="cont" cols="" placeholder="请填写加分描述(必填)"></textarea>
	    	</div>
	    	<div class="btn-footer">
	    		<button class="agree">确定加分</button>
	    	</div>
	    </div>
		<script src="__INDEX__/js/lib/zepto.js" type="text/javascript" charset="utf-8"></script>
		<script src="__INDEX__/mui/js/mui.min.js" type="text/javascript" charset="utf-8"></script>
		<script src="__INDEX__/mui/js/mui.view.js" type="text/javascript" charset="utf-8"></script>
		<script src="__INDEX__/layer_mobile/layer.js" type="text/javascript" charset="utf-8"></script>
		<script src="__INDEX__/js/common.js" type="text/javascript" charset="utf-8"></script>
		<script src="__INDEX__/js/lib/iscroll.js" type="text/javascript" charset="utf-8"></script>
		<script src="__INDEX__/js/coreIntManageBonus.js" type="text/javascript" charset="utf-8"></script>
		<script src="__INDEX__/js/maowenke.js" type="text/javascript" charset="utf-8"></script>
	<script>
		$(".goindex").on('tap',function () {
			window.location.href = "{:url('index/coreintmanage')}";
        });
		$(".agree").on('tap',function () {
			var $number = $("#number").val();
			var $change_describes = $("#cont").val();
			if(!$number||!$change_describes){
			    mui.alert('分数和描述是必填项');
				return;
			}
			var $userid = "{$jiafenren['id']}";
			$.post("{:url('add/change')}",{userid:$userid,number:$number,change_describes:$change_describes},function (data) {
				console.log(data);
			    if(data.code==200){
                    mui.alert(data.msg);
                    setTimeout(function () {
						window.location.reload();
                    },2000);
				}else{
				    mui.alert(data.msg);
				}
            });
        })
	</script>
	</body>
</html>
